<style>
    #preview {
        border:1px solid #ddd;padding:10px;
        height:500px;
        overflow-y: auto;
    }
    #preview img {
        width:100%;
    }
</style>
<form id="edit-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <div class="form-group">
        <label for="c-title" class="control-label col-xs-12 col-sm-2">{:__('Title')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-title" data-rule="required" class="form-control" name="row[title]" type="text" value="{$row.title}">
        </div>
    </div>
    <div class="form-group">
        <label for="c-type" class="control-label col-xs-12 col-sm-2">{:__('Type')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-type" data-rule="required" class="form-control" name="row[type]" type="text" value="{$row.type}">
        </div>
    </div>
    <div class="form-group">
        <label for="c-sort" class="control-label col-xs-12 col-sm-2">{:__('Order')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-order" data-rule="required" class="form-control" name="row[order]" type="number" value="{$row.order}">
        </div>
    </div>
    <div class="form-group">
        <label for="c-source" class="control-label col-xs-12 col-sm-2">{:__('Source')}:</label>
        <div class="col-xs-12 col-sm-8">
            <textarea id="c-source" data-rule="required" class="form-control" name="row[source]" rows="15">{$row.source}</textarea>
        </div>
    </div>
    <div class="form-group">
        <label for="c-preview" class="control-label col-xs-12 col-sm-2">{:__('Preview')}:</label>
        <div class="col-xs-12 col-sm-8">
            <div id="preview"></div>
        </div>
    </div>
    <div class="form-group">
        <label for="c-isnew" class="control-label col-xs-12 col-sm-2">{:__('Isnew')}:</label>
        <div class="col-xs-12 col-sm-8">
            <label for="row[isnew]-yes"><input id="row[isnew]-yes" {:$row['isnew']?'checked':''} name="row[isnew]" type="radio" value="1"> 是</label> 
            <label for="row[isnew]-no"><input id="row[isnew]-no" {:$row['isnew']?'':'checked'} name="row[isnew]" type="radio" value="0"> 否</label>
        </div>
    </div>
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
